Technical Field
Embodiments described herein generally relate to processors. In particular, embodiments described herein generally relate to processors to execute instructions to accelerate cryptographic algorithms.
Background Information
RSA (Ron Rivest, Adi Shamir, and Leonard Adleman) is a well-known and widely used public-key cryptography algorithm. The RSA algorithm is composed of key generation, encryption, and decryption. RSA is based on an RSA key pair that includes an RSA public key and an RSA private key. The RSA public key may be known publically (e.g., by anyone) and may be used to encrypt messages. The RSA private key is used to decrypt the messages. The RSA private key should not be publically known, but rather kept secret or reserved only for those who are intended to decrypt the encrypted messages. At a high level, the RSA algorithm is based on the presumed difficulty of factoring large integers. The RSA public key generally includes the product of two large prime numbers and an auxiliary value. The prime factors are kept secret and used to decrypt encrypted messages. The security provided by the RSA algorithm is based on the presumption that messages encrypted with the public key can only be decrypted feasibly and/or in a reasonable amount of time by using the private key. Further details on the RSA algorithm, if desired, are available in Request for Comments 3447, Public-Key Cryptography Standards (PKCS) #1: RSA Cryptography Specifications Version 2.1, by J. Jonsson and B. Kalinski of RSA Laboratories, February 2003. Further details on the RSA algorithm, if desired, are also available in U.S. Pat. No. 4,405,829. However, a detailed understanding of the RSA algorithm is not required to understand the embodiments of the invention disclosed herein.
As mentioned above, the RSA algorithm is a widely used public-key cryptography algorithm. As a result, significant effort has been expended over the years to increase the speed and efficiency of implementing the RSA algorithm. This has been done through both a hardware and software perspective. One of the more common ways of implementing the RSA algorithm is with the OpenSSL library. The OpenSSL library is an open source software library that supports various cryptographic algorithms including the RSA algorithm. However, even with the efforts to improve the speed and efficiency of implementing the RSA algorithm, its implementation often still tends to be relatively computationally intensive. Accordingly, further ways of improving the speed and/or efficiency of implementing the RSA algorithm would be advantageous.